Part Number Hot Search : 
2SA1845 APT30 LA38B WF031200 2N2007 F1012 P6KE36 RS801G
Product Description
Full Text Search
 

To Download R2025S Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  R2025S/d high precision i 2 c-bus real-time clock module no.ea-135-0603 1 outline the R2025S/d is a real-time clock module, built in cmos real-time clock ic and crystal oscillator, connected to the cpu by two signal lines, scl and sda, and configured to perform serial transmission of time and calendar data to the cpu. the oscillation frequenc y is adjusted to high precision (0 5ppm: 15sec. per month at 25 c) the periodic interrupt circuit is configured to generate interr upt signals with six selectable interrupts ranging from 0.5 seconds to 1 month. the 2 alarm interrupt circuits generat e interrupt signals at preset times. as the oscillation circuit is driven under constant voltage, fluctuation of the oscillator frequency due to supply voltage is small, and the time keeping current is small (typ. 0.48 a at 3v). the oscillation halt sensing circuit can be used to judge the validity of internal data in such events as power-on; the supply voltage monitoring circuit is configured to record a drop in supply voltage below two selectable supply voltage monitoring threshold settings. the 32-khz clock output function (cmos output) is intended to output sub-clock pul ses for the external microcomputer. the oscillation adjustment circuit is intended to adjust time by correct ing deviations in the oscillation frequency of the crystal oscillator. features ? built in 32.768khz crystal unit, the oscillati on frequency is adjusted to high precision (0 5ppm: at 25 c) ? time keeping voltage 1.15v to 5.5v ? super low power consumption 0.48 a typ (1.2 a max) at vdd=3v ? i2c-bus interface (maximum serial clock frequency: 400khz at vdd 1.7v) ? time counters (counting hours, minutes, and seconds) and calendar counters (counting years, months, days, and weeks) (in bcd format) ? interrupt circuit configured to generate interrupt signals (w ith interrupts ranging from 0.5 seconds to 1 month) to the cpu and provided with an interrupt flag and an interrupt halt ? 2 alarm interrupt circuits (alarm_w for week, hour , and minute alarm settings and alarm_d for hour and minute alarm settings) ? 32768hz clock cmos push-pull output with control pin ? with power-on flag to prove that the power supply starts from 0v ? with oscillation halt sensing flag to judge the validity of internal data ? supply voltage monitoring circuit with two supply voltage monitoring threshold settings ? automatic identification of leap years up to the year 2099 ? selectable 12-hour and 24-hour mode settings ? oscillation adjustment circuit for correcting te mperature frequency deviation or offset deviation ? cmos process ? two types of package, sop14(10.1x7. 4x3.1) or son22(6.1x5.0x1.3)
R2025S/d 2 pin configuration scl sda /intra vss vdd n.c. 1 2 3 4 5 6 7 9 top view R2025S (sop14) 32kout 10 8 /intrb 11 12 13 14 n.c. vpp n.c. n.c. clkc n.c. scl sda /intra vss vdd clkc 1 2 3 4 5 6 7 9 top view r2025d (son22) 32kout 10 8 /intrb 11 15 16 14 vpp n.c. n.c. n.c. n.c. n.c. n.c. n.c. n.c. n.c. n.c. n.c. 18 19 17 21 22 20 block diagram 32khz output control osc comparator_d alarm_d register (min,hour) address decoder address register voltage detect div time counter (sec,min,hour,week,day,month,year) shift register i/o control 32kout interrupt control sda scl /intra divider correc -tion vdd vss comparator_w alarm_w register (min,hour, week) clkc osc detect /intrb test circuit vpp
R2025S/d 3 pin description symbol item description scl serial clock line the scl pin is used to input clo ck pulses synchronizing the input and output of data to and from the sda pin. allows a maximum input voltage of 5.5 volts regardless of supply voltage. sda serial data line the sda pin is used to input or output data intended for writing or reading in synchronization with the scl pin. up to 5.5v beyond vdd may be input. this pin functions as an n-ch open drain output. /intra interrupt output a the /intra pin is used to output alarm interrupt (alarm_d) and output periodic interrupt signals to the cp u signals. disabled at power-on from 0v. n-ch. open drain output. /intrb interrupt output b the /intra pin is used to output alarm interrupt (alarm_w) and output periodic interrupt signals to the cp u signals. disabled at power-on from 0v. n-ch. open drain output. 32kout 32k clock output the 32kout pin is used to output 32.768-khz clock pulses. enabled at power-on from 0 volts. cmos output. the output is disabled and held ?l? when clkc pi set to ?l? or open, or certain register setting. this pin is enabled at power-on from 0v. clkc clock control input the clkc pin is used to control out put of the 32kout pin. the clock output is disabled and held low when the pin is set to low or open. incorporates a pull-down resistor. vdd vss positive power supply input negative power supply input the vdd pin is connected to the power supply. the vss pin is grounded. vpp test input this pin is power pin for testi ng in the factory. don?t connect to any lines. n.c. no connection these pins are not connected to internal ic chip. in r2025d (son22), n.c. pins fr om 14 pin to 22 pin are connected together internally. never connect thes e pins to any lines, or connect to vdd or vss. and never connect differ ent voltage level lines each other.
R2025S/d 4 absolute maximum ratings (vss=0v) symbol item pin name and condition description unit vdd supply voltage vdd -0.3 to +6.5 v input voltage 1 scl, sda, clkc -0.3 to +6.5 vi input voltage 2 vpp -0.3 to vdd+0.3 v output voltage 1 sda, /intr a, /intrb -0.3 to +6.5 vo output voltage 2 32kout -0.3 to vdd+0.3 v pd power dissipation topt=25 c 300 mw topt operating temperature -40 to +85 c tstg storage temperature -55 to +125 c recommended operating condition (vss=0v, topt=-40 to +85 c) symbol item pin name min. typ. max. unit vdd supply voltage 1.7 5.5 v vclk time keeping voltage 1.15 5.5 v vpup pull-up voltage scl, sda, /intra, /intrb 5.5 v rpup pull-up resister clkc 10 k ? frequency characteristics (vss=0v) symbol item condition min. typ. max. unit ? f/f0 frequency deviation topt=25 c, vdd=3v -5 0 +5 ppm fv frequency voltage characteristics topt=25 c, vdd=2.0v to 5.5v -1 +1 ppm top frequency temperature characteristics topt=-20 c to +70 c 25 c as standard -120 +10 ppm tsta oscillation start-up time topt=25 c, vdd=2v 1 sec fa aging topt=25 c, vdd=3v, first year -5 +5 ppm
R2025S/d 5 dc electrical characteristics unless otherwise specified: vss=0v,vdd=3v,topt=-40 to +85 c symbol item pin name condition min. typ. max. unit vih ?h? input voltage 0.8x vdd 5.5 vil ?l? input voltage scl,sda, clkc vdd=1.7 to 5.5v -0.3 0.2x vdd v ioh ?h? output current 32kout voh=vdd-0.5v -0.5 ma iol1 32kout 0.5 iol2 /intra, /intrb 1.0 iol3 ?l? output current sda vol=0.4v 4.0 ma iil input leakage current scl vi=5.5v or vss vdd=5.5v -1.0 1.0 a iclkc pull-down resistance input current clkc vi=5.5v 0.3 1.0 a ioz output off-state leakage current sda, /intra /intrb vo=5.5v or vss vdd=5.5v -1.0 1.0 a idd1 vdd vdd=3v, scl=sda=3v, output = open clkc=?l? 0.48 1.20 a idd2 time keeping current vdd vdd=5v, scl=sda=5v, output = open clkc=?l? 0.60 1.80 a vdeth supply voltage monitoring voltage (?h?) vdd topt=-30 to +70 c 1.90 2.10 2.30 v vdetl supply voltage monitoring voltage (?l?) vdd topt=-30 to +70 c 1.15 1.30 1.45 v
R2025S/d 6 ac electrical characteristics unless otherwise specified: vss=0v,topt=-40 to +85 c input / output condition: vi h=0.8xvdd,vil=0.2x vdd,voh=0.8xvdd,vo l=0.2xvdd,cl=50pf vdd 1.7v symbol item condi- tion min. typ. max. unit f scl scl clock frequency 400 khz t low scl clock ?l? time 1.3 s t high scl clock ?h? time 0.6 s t hd;sta start condition hold time 0.6 s t su;sto stop condition set up time 0.6 s t su;sta start condition set up time 0.6 s t rcv ricovery time from stop condition to start condition 62 s t su;dat data set up time 200 ns t hd;dat data hold time 0 ns t pl;dat sda ?l? stable time after falling of scl 0.9 s t pz;dat sda off stable time after falling of scl 0.9 s t r rising time of scl and sda (input) 300 ns t f falling time of scl and sda (input) 300 ns t sp spike width that can be removed with input filter 50 ns sda(out) scl s sr p t pz ; dat t high t su ; dat t hd ; sta t sp t su ; sto t low t su ; sta sda(in) t hd ; sta t pl ; dat sr p stop condition s start condition repeated start condition t hd ; dat t rcv s
R2025S/d 7 package dimensions ? R2025S (sop14) # 14 # 7 # 1 # 8 5.0 0.2 10.1 0.2 7.4 0.2 0.6 0.25 0.15 +0.1/-0.05 0 -10 0.35 +0.1/-0.05 1.27 0.1 1.2 0.1 +0.1/-0.05 3.1 +0.0/-0.05 0.1 1.24typ. ? r2025d (son22) a 6.1 0.2 # 22 # 14 # 1 # 11 4.7 0.2 5.0 0.2 0.2 0.1 0.5 0.1 0.1 0.125 +0.1/-0.05 1.3 0.1 # 1 # 11 # 22 # 14 0.3 0.1 0.43 0.43 0.05 a b a ? b b 0.2 0.2 0.1 0.3 0.65 a ? 0.3 0.2 0.55typ.
R2025S/d 8 general description ? interface with cpu the R2025S/d is connected to the cpu by two signal lines scl and sda, through which it reads and writes data from and to the cpu. since the output of the i/o pin of sda is open drain, data interfacing with a cpu different supply voltage is possible by applying pull-up re sistors on the circuit board. the maximum clock frequency of 400khz (at vdd 1.7v) of scl enables data transfer in i 2 c-bus fast mode. ? clock and calendar function the R2025S/d reads and writes time data from and to the cpu in units ranging from seconds to the last two digits of the calendar year. the calendar year will automatic ally be identified as a leap year when its last two digits are a multiple of 4. consequently, leap years up to the year 2099 can automatica lly be identified as such. ? alarm function the R2025S/d incorporates the alarm interrupt circuit configured to generate interr upt signals to the cpu at preset times. the alarm interrupt ci rcuit allows two types of alarm settings specified by the alarm_w registers and the alarm_d registers. the alarm_w registers allow week, hour, and minute alarm settings including combinations of multiple day-of-week settings such as "monday, wednesday, and friday" and "saturday and sunday". the alarm_d registers allow hour and minute al arm settings. the alarm_w outputs from /intrb pin, and the alarm_d outputs from /intra pin. the current /intr a or /intrb conditions specified by the flag bits for each alarm function can be checked from the cpu by using a polling function. ? high-precision oscillation adjustment function to correct deviations in the oscillation frequency of the cr ystal oscillator, the oscillation adjustment circuit is configured to allow correction of a time count gain or loss (up to 1.5 ppm at 25 c) from the cpu within a maximum range of approximately + 189 ppm in increment s of approximately 3 ppm. such oscillation frequency adjustment in each system has the following advantages: * corrects seasonal frequency deviations through seasonal oscillation adjustment. * allows timekeeping with higher precision particularly with a temperature sensing function out of rtc, through oscillation adjustment in tune with temperature fluctuations. ? oscillation halt sensing flag, power-on reset flag, and supply voltage monitoring function the R2025S/d incorporates an oscillation halt sensing ci rcuit equipped with internal registers configured to record any past oscillation halt. power-on reset flag is set to ?1? w hen R2025S/d is powered on from 0v. as such, the oscillation halt sensing flag and power-on reset flag are useful for judging the validity of time data. the R2025S/d also incorporates a supply voltage monito ring circuit equipped with internal registers configured to record any drop in supply voltage below a certain threshold value. supply voltage monitoring threshold settings can be selected between 2.1 and 1.3 volts through internal regi ster settings. the oscillation halt sensing circuit is configured to confirm the established invalidation of time data in contrast to the supply voltage monitoring circuit intended to confirm the potential invalidation of time dat a. further, the supply voltage monitoring circuit can be applied to battery supply voltage monitoring. ? periodic interrupt function the R2025S/d incorporates the periodic interrupt circui t configured to generate periodic interrupt signals aside from interrupt signals generated by the per iodic interrupt circuit for output from the /intra pin. periodic interrupt signals have five selectable frequency settings of 2 hz (onc e per 0.5 seconds), 1 hz (once per 1 second), 1/60 hz (once per 1 minute), 1/3600 hz (once per 1 hour), and monthl y (the first day of every month). further, periodic interrupt signals also have two selectable waveforms, a normal pulse form (with a frequency of 2 hz or 1 hz) and
R2025S/d 9 special form adapted to interruption from the cpu in the level mode (with second, minute, hour, and month interrupts). the condition of periodic interrupt si gnals can be monitored by using a polling function. ? 32khz clock output the R2025S/d incorporates a 32-khz clock output circuit configured to generate clock pulses with the oscillation frequency of a 32.768khz crystal oscillator for output from the 32kout pin (cmos push-pull output). the 32-khz clock output is enabled and disabled when the clkc pin is held high, and low or open, respectively. the 32-khz clock output can be disabled by certai n register settings but cannot be dis abled without manipulation of any two registers with different addresses to prevent disabli ng in such events as the runaway of the cpu.
R2025S/d 10 address mapping address register name d a t a a3a2a1a0 d7 d6 d5 d4 d3 d2 d1 d0 0 0 0 0 0 second counter - *2) s40 s20 s10 s8 s4 s2 s1 1 0 0 0 1 minute counter - m40 m20 m10 m8 m4 m2 m1 2 0 0 1 0 hour counter - - h20 p ? /a h10 h8 h4 h2 h1 3 0 0 1 1 day-of-week counter - - - - - w4 w2 w1 4 0 1 0 0 day-of-month counter - - d20 d10 d8 d4 d2 d1 5 0 1 0 1 month counter and century bit /19 ? 20 - - mo10 mo8 mo4 mo2 mo1 6 0 1 1 0 year counter y80 y40 y20 y10 y8 y4 y2 y1 7 0 1 1 1 oscillation adjustment register *3) (0) *4) f6 f5 f4 f3 f2 f1 f0 8 1 0 0 0 alarm_w (minute register) - wm40 wm20 wm10 wm8 wm4 wm2 wm1 9 1 0 0 1 alarm_w (hour register) - - wh20 wp ? / a wh10 wh8 wh4 wh2 wh1 a 1 0 1 0 alarm_w (day-of-week register) - ww6 ww5 ww4 ww3 ww2 ww1 ww0 b 1 0 1 1 alarm_d (minute register) - dm40 dm20 dm10 dm8 dm4 dm2 dm1 c 1 1 0 0 alarm_d (hour register) - - dh20 dp ? /a dh10 dh8 dh4 dh2 dh1 d 1 1 0 1 - - - - - - - - e 1 1 1 0 control register 1 *3) wale dale /12 ? 24 /clen2 test ct2 ct1 ct0 f 1 1 1 1 control register 2 *3) vdsl vdet /xst pon *5) /clen1 ctfg wafg dafg notes: *1) all the data listed above a ccept both reading and writing. *2) the data marked with "-" is invalid for writing and reset to 0 for reading. *3) when the pon bit is set to 1 in control register 2, all the bits are reset to 0 in oscillation adjustment register, control register 1 and contro l register 2 excluding the /xst and pon bits. *4) the (0) bit should be set to 0. *5) /xst is oscillation halt sensing bit. *6) pon is power-on reset flag.
R2025S/d 11 register settings ? control register 1 (address eh) d7 d6 d5 d4 d3 d2 d1 d0 wale dale /12 ? 24 /clen2 test ct2 ct1 ct0 (for writing) wale dale /12 ? 24 /clen2 test ct2 ct1 ct0 (for reading) 0 0 0 0 0 0 0 0 default settings *) *) default settings: default value means read / writt en values when the pon bit is set to ?1? due to vdd power-on from 0 volts. (1) wale, dale alarm_w enable bit, alarm_d enable bit wale,dale description 0 disabling the alarm interrupt circui t (under the control of the settings of the alarm_w registers and the alarm_d registers). (default) 1 enabling the alarm interrupt circui t (under the control of the settings of the alarm_w registers and the alarm_d registers) (2) /12 ? 24 /12-24-hour mode selection bit /12 ? 24 description 0 selecting the 12-hour mode with a. m. and p.m. indications. (default) 1 selecting the 24-hour mode setting the /12 ? 24 bit to 0 and 1 specifies the 12-hour mode and the 24-hour mode, respectively. 24-hour mode 12-hour mode 24-hour mode 12-hour mode 00 12 (am12) 12 32 (pm12) 01 01 (am 1) 13 21 (pm 1) 02 02 (am 2) 14 22 (pm 2) 03 03 (am 3) 15 23 (pm 3) 04 04 (am 4) 16 24 (pm 4) 05 05 (am 5) 17 25 (pm 5) 06 06 (am 6) 18 26 (pm 6) 07 07 (am 7) 19 27 (pm 7) 08 08 (am 8) 20 28 (pm 8) 09 09 (am 9) 21 29 (pm 9) 10 10 (am10) 22 30 (pm10) 11 11 (am11) 23 31 (pm11) setting the /12 ? 24 bit should precede writing time data (3) /clen2 32-khz clock output bit2 /clen2 description 0 enabling the 32-khz clock output (default) 1 disabling the 32-khz clock output setting the /clen2 bit or the /clen1 bit (d3 in the cont rol register 2) to 0 specifies generating clock pulses with the oscillation frequency of the 32.768-khz crys tal oscillator for output from the 32kout pin. conversely, setting both the /clen1 and the /clen2 bit to 1 specifies disabling (?l?) such output. (4) test test bit test description 0 normal operation mode. (default) 1 test mode. the test bit is used only for testing in the factory and should normally be set to 0.
R2025S/d 12 (5) ct2,ct1, and ct0 periodic interrupt selection bits description ct2 ct1 ct0 wave form mode interrupt cycle and falling timing 0 0 0 - off(h) (default) 0 0 1 - fixed at ?l? 0 1 0 pulse mode *1) 2hz(duty50%) 0 1 1 pulse mode *1) 1hz(duty50%) 1 0 0 level mode *2) once per 1 second (synchronized with second counter increment) 1 0 1 level mode *2) once per 1 minute (at 00 seconds of every minute) 1 1 0 level mode *2) once per hour (at 00 minutes and 00 seconds of every hour) 1 1 1 level mode *2) once per month (at 00 hours, 00 minutes, and 00 seconds of first day of every month) * 1) pulse mode: 2-hz and 1-hz clock pulses are output in synchronization with the increment of the second counter as illustrated in the timing chart below. /intra pin rewriting of the second counter ctfg bit a pprox. 92 s (increment of second counter) in the pulse mode, the increment of the second counter is delayed by approximately 92 s from the falling edge of clock pulses. consequently, time readings i mmediately after the falling edge of clock pulses may appear to lag behind the time counts of the real-time clocks by approximately 1 second. rewriting the second counter will reset the other time counters of less than 1 second, driving the /intra pin low. * 2) level mode: periodic interrupt signals are output with selectable inte rrupt cycle settings of 1 second, 1 minute, 1 hour, and 1 month. the in crement of the second counter is synchronized with the falling edge of periodic interrupt signals. for example, periodic inte rrupt signals with an interrupt cycle setting of 1 second are output in synchronization with the increment of the second counter as illustrated in the timing chart below. ctfg bit /intra pin setting ctfg bit to 0 setting ctfg bit to 0 (increment of second counter) (increment of second counter) (increment of second counter)
R2025S/d 13 *1), *2) when the oscillation adjustment circuit is used, the interrupt cycle will fluctuate once per 20sec. or 60sec. as follows: pulse mode: the ?l? period of output pulses w ill increment or decrement by a maximum of 3.784 ms. for example, 1-hz clock pulses will have a duty cycle of 50 0.3784%. level mode: a periodic interrupt cycle of 1 sec ond will increment or decrement by a maximum of 3.784 ms. ? control register 2 (address fh) d7 d6 d5 d4 d3 d2 d1 d0 vdsl vdet /xst pon /cle n1 ctfg waf g dafg (for writing) vdsl vdet /xst pon /cle n1 ctfg waf g dafg (for reading) 0 0 indefinit e 1 0 0 0 0 default settings *) *) default settings: default value means read / writt en values when the pon bit is set to ?1? due to vdd power-on from 0 volts. (1) vdsl vdd supply voltage monitoring threshold selection bit vdsl description 0 selecting the vdd supply voltage monitoring threshold setting of 2.1v. (default) 1 selecting the vdd supply voltage monitoring threshold setting of 1.3v. the vdsl bit is intended to select the v dd supply voltage monitoring threshold settings. (2) vdet supply voltage monitoring result indication bit vdet description 0 indicating supply voltage above the supply voltage monitoring threshold settings. (default) 1 indicating supply voltage below the supply voltage monitoring threshold settings. once the vdet bit is set to 1, the supply voltage m onitoring circuit will be disabled while the vdet bit will hold the setting of 1. the vdet bit accepts only t he writing of 0, which restarts the supply voltage monitoring circuit. conversely, setting the vdet bit to 1 causes no event. (3) /xst oscillation halt sensing monitor bit /xst description 0 sensing a halt of oscillation 1 sensing a normal condition of oscillation the /xst accepts the reading and writing of 0 and 1. t he /xst bit will be set to 0 when the oscillation halt sensing. the /xst bit will hold 0 even after the restart of oscillation. (4) pon power-on-reset flag bit pon description 0 normal condition 1 detecting vdd power-on -reset (default) the pon bit is for sensing power-on reset condition. * the pon bit will be set to 1 when vdd power-on from 0 volts. the pon bit will hold the setting of 1 even after power-on. * when the pon bit is set to 1, all bits will be reset to 0, in the oscillation adjustment register, control register 1, and control register 2, except /xst and pon. as a result, /intra and /intrb pins stop outputting. * the pon bit accepts only the writing of 0. conv ersely, setting the pon bit to 1 causes no event.
R2025S/d 14 (5) /clen1 32-khz clock output bit 1 /clen1 description 0 enabling the 32-khz clock output (default) 1 disabling the 32-khz clock output setting the /clen1 bit or the /clen2 bit (d4 in the cont rol register 1) to 0 specifies generating clock pulses with the oscillation frequency of the 32.768-khz crys tal oscillator for output from the 32kout pin. conversely, setting both the /clen1 and the /clen2 bit to 1 specifies disabling (?l?) such output. (6) ctfg periodic interrupt flag bit ctfg description 0 periodic interrupt output = ?h? (default) 1 periodic interrupt output = ?l? the ctfg bit is set to 1 when the periodic interrupt signals are output from the /intra pin (?l?). the ctfg bit accepts only the writing of 0 in the level mode, which disables (?h?) the /intra pin until it is enabled (?l?) again in the next interrupt cycle. conver sely, setting the ctfg bit to 1 causes no event. (7) wafg,dafg alarm_w flag bit and alarm_d flag bit wafg,dafg description 0 indicating a mismatch between current ti me and preset alarm time (default) 1 indicating a match between current time and preset alarm time the wafg and dafg bits are valid only when the wale and dale have the setting of 1, which is caused approximately 61 s after any match between current time and pres et alarm time specified by the alarm_w registers and the alarm_d registers. the wafg (daf g) bit accepts only the writing of 0. /intrb (/intra) pin outputs off (?h?) when this bit is set to 0. and /intrb ( /intra) pin outputs ?l? again at the next preset alarm time. conversely, setting the wafg and dafg bits to 1 causes no event. the wafg and dafg bits will have the reading of 0 when the alarm interrupt circuit is disabled with the wale and dale bits set to 0. the settings of the wafg (d afg) bit is synchronized with the output of the /intrb (/intra) pin as show n in the timing chart below. /intrb(/intra) pin writing of 0 to wafg(dafg) bit wafg(dafg) bit (match between current time and preset alarm time) a pprox. 61 s a pprox. 61 s writing of 0 to wafg(dafg) bit (match between current time and preset alarm time) (match between current time and preset alarm time)
R2025S/d 15 ? time counter (address 0-2h) second counter (address 0h) d7 d6 d5 d4 d3 d2 d1 d0 - s40 s20 s10 s8 s4 s2 s1 (for writing) 0 s40 s20 s10 s8 s4 s2 s1 (for reading) 0 indefinite indefinite indefinite indefinite indefinite indefinite indefinite default settings *) minute counter (address 1h) d7 d6 d5 d4 d3 d2 d1 d0 - m40 m20 m10 m8 m4 m2 m1 (for writing) 0 m40 m20 m10 m8 m4 m2 m1 (for reading) 0 indefinite indefinite indefinite indefinite indefinite indefinite indefinite default settings *) hour counter (address 2h) d7 d6 d5 d4 d3 d2 d1 d0 - - p ? /a or h20 h10 h8 h4 h2 h1 (for writing) 0 0 p ? /a or h20 h10 h8 h4 h2 h1 (for reading) 0 0 indefinite indefinite indefinite indefinite indefinite indefinite default settings *) *) default settings: default value means read / writt en values when the pon bit is set to ?1? due to vdd power-on from 0 volts. * time digit display (bcd format) as follows: the second digits range from 00 to 59 and are carried to the minute digit in transition from 59 to 00. the minute digits range from 00 to 59 and are carried to the hour digits in transition from 59 to 00. the hour digits range as shown in "p11 ? control register 1 (address eh) (2) /12 ? 24: /12-24-hour mode selection bit" and are carried to the day-of-month and day -of-week digits in transition from pm11 to am12 or from 23 to 00. * any writing to the second counter resets divider units of less than 1 second. * any carry from lower digits with the writing of non-exis tent time may cause the time counters to malfunction. therefore, such incorrect writing should be replac ed with the writing of existent time data. ? day-of-week counter (address 3h) d7 d6 d5 d4 d3 d2 d1 d0 - - - - - w4 w2 w1 (for writing) 0 0 0 0 0 w4 w2 w1 (for reading) 0 0 0 0 0 indefinite indefinite indefinite default settings *) *) default settings: default value means read / writt en values when the pon bit is set to ?1? due to vdd power-on from 0 volts. * the day-of-week counter is incremented by 1 when t he day-of-week digits are carried to the day-of-month digits. * day-of-week display (incremented in septimal notation): (w4, w2, w1) = (0, 0, 0) (0, 0, 1) ? (1, 1, 0) (0, 0, 0) * correspondences between days of the week and t he day-of-week digits are user-definable (e.g. sunday = 0, 0, 0) * the writing of (1, 1, 1) to (w4, w2, w1) is prohibited except when days of the week are unused.
R2025S/d 16 ? calendar counter (address 4-6h) day-of-month counter (address 4h) d7 d6 d5 d4 d3 d2 d1 d0 - - d20 d10 d8 d4 d2 d1 (for writing) 0 0 d20 d10 d8 d4 d2 d1 (for reading) 0 0 indefinite indefinite indefinite indefinite indefinite indefinite default settings *) month counter + century bit (address 5h) d7 d6 d5 d4 d3 d2 d1 d0 /19 ? 20 - - mo10 mo8 mo4 mo2 mo1 (for writing) /19 ? 20 0 0 mo10 mo8 mo4 mo2 mo1 (for reading) indefinite 0 0 indefinite indefinite indefinite indefinite indefinite default settings *) year counter (address 6h) d7 d6 d5 d4 d3 d2 d1 d0 y80 y40 y20 y10 y8 y4 y2 y1 (for writing) y80 y40 y20 y10 y8 y4 y2 y1 (for reading) indefinite indefinite indefinite indefinite indefinite indefinite indefinite indefinite default settings *) *) default settings: default value means read / writt en values when the pon bit is set to ?1? due to vdd power-on from 0 volts. * the calendar counters are configured to display the ca lendar digits in bcd format by using the automatic calendar function as follows: the day-of-month digits (d20 to d1) range from 1 to 31 for january, march, may, july, august, october, and december; from 1 to 30 for april, june, september, and november; from 1 to 29 for february in leap years; from 1 to 28 for february in ordinary years. the day -of-month digits are carried to the month digits in reversion from the last day of the month to 1. t he month digits (mo10 to mo1) range from 1 to 12 and are carried to the year digits in reversion from 12 to 1. the year digits (y80 to y1) range from 00 to 99 (00, 04, 08, , 92, and 96 in leap years) and are carried to the /19 ? 20 digits in reversion from 99 to 00. the /19 ? 20 digits cycle between 0 and 1 in reversion from 99 to 00 in the year digits. * any carry from lower digits with the writing of non-existent calendar data may cause the calendar counters to malfunction. therefore, such in correct writing should be replaced with the writing of existent calendar data. ? oscillation adjustment register (address 7h) d7 d6 d5 d4 d3 d2 d1 d0 (0) f6 f5 f4 f3 f2 f1 f0 (for writing) 0 f6 f5 f4 f3 f2 f1 f0 (for reading) 0 0 0 0 0 0 0 0 default settings *) *) default settings: default value means read / writt en values when the pon bit is set to ?1? due to vdd power-on from 0 volts. (0) bit: (0) bit should be set to 0 f6 to f0 bits: * the oscillation adjustment circuit is configured to change time counts of 1 second on the basis of the settings of the oscillation adjustment register when t he second digits read 00, 20, or 40 seconds. normally,
R2025S/d 17 the second counter is incremented once per 32768 32.768-khz clock pulses generated by the crystal oscillator. writing to the f6 to f0 bits activates the oscillation adjustment circuit. * the oscillation adjustment circuit will not operate with the same timing (00, 20, or 40 seconds) as the timing of writing to the oscillation adjustment register. * the f6 bit setting of 0 causes an increment of time counts by ((f5, f4, f3, f2, f1, f0) - 1) x 2. the f6 bit setting of 1 causes a decrement of time count s by ((/f5, /f4, /f3, /f2, /f1, /f0) + 1) x 2. the settings of "*, 0, 0, 0, 0, 0, *" ("*" representing either "0" or "1") in the f6, f5, f4, f3, f2, f1, and f0 bits cause neither an increment nor decrement of time counts. example: when the second digits read 00, 20, or 40, the settings of "0 , 0, 0, 0, 1, 1, 1" in the f6, f5, f4, f3, f2, f1, and f0 bits cause an increment of the current time counts of 32768 by (7 - 1) x 2 to 32780 (a current time count loss). when the second digits read 00, 20, or 40, the settings of "0, 0, 0, 0, 0, 0, 1" in the f6, f5, f4, f3, f2, f1, and f0 bits cause neither an increment nor a dec rement of the current time counts of 32768. when the second digits read 00, 20, or 40, the settings of "1 , 1, 1, 1, 1, 1, 0" in the f6, f5, f4, f3, f2, f1, and f0 bits cause a decrement of the current time count s of 32768 by (- 2) x 2 to 32764 (a current time count gain). an increase of two clock pulses once per 20 seconds c auses a time count loss of approximately 3 ppm (2 / (32768 x 20 = 3.051 ppm). conversely, a decrease of tw o clock pulses once per 20 seconds causes a time count gain of 3 ppm. consequently, deviations in ti me counts can be corrected with a precision of 1.5 ppm. note that the oscillation adjustment circuit is confi gured to correct deviations in time counts and not the oscillation frequency of the 32.768-khz clock pulses. for further details, see "p28 configuration of oscillation circuit and correction of time count deviations ? oscillation adjustment circuit".
R2025S/d 18 ? alarm_w registers (address 8-ah) alarm_w minute register (address 8h) d7 d6 d5 d4 d3 d2 d1 d0 - wm40 wm20 wm10 wm8 wm4 wm2 wm1 (for writing) 0 wm40 wm20 wm10 wm8 wm4 wm2 wm1 (for reading) 0 indefinite indefinite indefinite indefinite indefinite indefinite indefinite default settings *) alarm_w hour register (address 9h) d7 d6 d5 d4 d3 d2 d1 d0 - - wh20 wp ? /a wh10 wh8 wh4 wh2 wh1 (for writing) 0 0 wh20 wp ? /a wh10 wh8 wh4 wh2 wh1 (for reading) 0 0 indefinite indefinite indefinite indefinite indefinite indefinite default settings *) alarm_w day-of-week register (address ah) d7 d6 d5 d4 d3 d2 d1 d0 - ww6 ww5 ww4 ww3 ww2 ww1 ww0 (for writing) 0 ww6 ww5 ww4 ww3 ww2 ww1 ww0 (for reading) 0 indefinite indefinite indefinite indefinite indefinite indefinite indefinite default settings *) *) default settings: default value means read / writt en values when the pon bit is set to ?1? due to vdd power-on from 0 volts. * the d5 bit of the alarm_w hour register represent s wp/a when the 12-hour mode is selected (0 for a.m. and 1 for p.m.) and wh20 when the 24-hour mode is selected (tens in the hour digits). * the alarm_w registers should not have any non-existent alarm time settings. (note that any mismatch between curr ent time and preset alarm time spec ified by the alarm_w registers may disable the alarm interrupt circuit.) * when the 12-hour mode is selected, the hour digits read 12 and 32 for 0 a.m. and 0 p.m., respectively. (see "p11 ? control register 1 (address eh) (2) /12 ? 24: 12-/24-hour mode selection bit") * ww0 to ww6 correspond to w4, w2, and w1 of the day-o f-week counter with settings ranging from (0, 0, 0) to (1, 1, 0). * ww0 to ww6 with respective settings of 0 disable the outputs of t he alarm_w registers.
R2025S/d 19 example of alarm time setting alarm day-of-week 12-hour mode 24-hour mode preset alarm time sun . mon . tue. wed . th. fri. sat. 1 0 h r. 1 h r . 1 0 m in . 1 m in . 1 0 h r . 1 h r. 1 0 m in . 1 mi n. ww0 ww1 ww2 ww3 ww4 ww5 ww6 00:00 a.m. on all days 1 1 1 1 1 1 1 1 2 0 0 0 0 0 0 01:30 a.m. on all days 1 1 1 1 1 1 1 0 1 3 0 0 1 3 0 11:59 a.m. on all days 1 1 1 1 1 1 1 1 1 5 9 1 1 5 9 00:00 p.m. on mon. to fri. 0 1 1 1 1 1 0 3 2 0 0 1 2 0 0 01:30 p.m. on sun. 1 0 0 0 0 0 0 2 1 3 0 1 3 3 0 11:59 p.m. on mon. ,wed., and fri. 0 1 0 1 0 1 0 3 1 5 9 2 3 5 9 note that the correspondence between ww0 to ww6 and the days of the week shown in the above table is only an example and not mandatory. ? alarm_d register (address b-ch) alarm_d minute register (address bh) d7 d6 d5 d4 d3 d2 d1 d0 - dm40 dm20 dm10 dm8 dm4 dm2 dm1 (for writing) 0 dm40 dm20 dm10 dm8 dm4 dm2 dm1 (for reading) 0 indefinite indefinite indefinite indefinite indefinite indefinite indefinite default settings *) alarm_d hour register (address ch) d7 d6 d5 d4 d3 d2 d1 d0 - - dh20 dp ? /a dh10 dh8 dh4 dh2 dh1 (for writing) 0 0 dh20 dp ? /a dh10 dh8 dh4 dh2 dh1 (for reading) 0 0 indefinite indefinite indefinite indefinite indefinite indefinite default settings *) *) default settings: default value means read / writt en values when the pon bit is set to ?1? due to vdd power-on from 0 volts. * the d5 bit represents dp/a when the 12-hour mode is selected (0 for a.m. and 1 for p.m.) and dh20 when the 24-hour mode is selected (tens in the hour digits). * the alarm_d registers should not have any non-existent alarm time settings. (note that any mismatch between current time and preset alarm time specified by the alarm_d registers may disable the alarm interrupt circuit.) * when the 12-hour mode is selected, the hour digits read 12 and 32 for 0a.m. and 0p.m., respectively. (see "p11 ? control register 1 (address eh) (2) /12 ? 24: 12-/24-hour mode selection bit")
R2025S/d 20 interfacing with the cpu the R2025S/d employs the i 2 c-bus system to be connected to the cpu via 2-wires. connection and system of i 2 c-bus are described in the following sections. connection of i 2 c-bus 2-wires, scl and sda pins that are connected to i 2 c-bus are used for transmit clock pulses and data respectively. all ics that are connected to these lines are designed that will not be clamped when a voltage beyond supply voltage is applied to input or output pins. open drain pins are used for output. this construction allows communication of signals between ics with differ ent supply voltages by adding a pull-up resistor to each signal line as shown in the figure below. each ic is designed not to affect scl and sda signal lines when power to each of these is turned off separately. micro- controller R2025S/d other peripheral device vdd1 vdd2 vdd3 vdd4 scl sda * for data interface, the following conditions must be met: vcc4 vcc1 vcc4 vcc2 vcc4 vcc3 * when the master is one, the micro-controller is ready for driving scl to ?h? and rp of scl may not be required. rp rp cautions on determining rp resistance, (1) dropping voltage at rp due to sum of input current or output current at off conditions on each ic pin connected to the i 2 c-bus shall be adequately small. (2) rising time of each signal be kept short ev en when all capacity of the bus is driven. (3) current consumed in i 2 c-bus is small compared to the consumpti on current permitted for the entire system. when all ics connected to i 2 c-bus are cmos type, condition (1) may usually be ignored since input current and off-state output current is extremely sm all for the many cmos type ics. t hus the maximum resistance of rp may be determined based on (2), while the minimum on (3) in most cases. in actual cases a resistor may be place between the bus and input/output pins of each ic to improv e noise margins in which case the rp minimum value may be determined by the resistance. consumption current in the bus to review (3) above may be expressed by the formula below: bus consumption current (sum of input current and off state output current of all devices in standby mode ) bus standby duration bus stand-by duration + the bus operation duration + supply voltage bus operation duration 2 rp resistance 2 (bus stand-by duration + bus operation duration) + supply voltage bus capacity charging/discharging times per unit time operation of ? 2? in the second member denominator in the abov e formula is derived from assumption that ?l?
R2025S/d 21 duration of sda and scl pins are the half of bus operation duration. ? 2? in the numerator of the same member is because there are two pins of sda and scl. the third member, (charging/discharging times per unit time) means number of transition from ?h? to ?l? of the signal line. calculation example is shown below: pull-up resistor (rp) = 10k ? , bus capacity = 50pf(both for scl, sda), vdd=3v, in a system with sum of input current and off-state output current of each pin = 0.1 a, i 2 c-bus is used for 10ms every second while the rest of 990ms in the stand-by mode, in this mode, number of transitions of the scl pin fr om ?h? to ?l? state is 100 while sda 50, every second. bus consumption current 0.1 a 990msec 990msec + 10msec + 3v 10msec 2 10k ? 2 (990msec + 10msec) + 3v 50pf (100 + 50) 0.099 a + 3.0 a + 0.0225 a 3.12 a generally, the second member of the above formula is larger enough than the first and the third members bus consumption current may be determined by the second member is many cases. ? transmission system of i 2 c-bus (1) start condition and stop condition in i 2 c-bus, sda must be kept at a certain state while sc l is at the ?h? state during data transmission as shown below. scl sda tsu;dat thd;dat the scl and sda pins are at the ?h? level when no dat a transmission is made. changing the sda from ?h? to ?l? when the scl and the sda are ?h? activates the star t condition and access is started. changing the sda from ?l? to ?h? when the scl is ?h? activates stop c ondition and accessing stopped. generation of start and stop conditions are always made by the master (see the figure below).
R2025S/d 22 scl sda thd;sta tsu;sto start condition stop condition (2) data transmission and its acknowledge after start condition is entered, data is transmitted by 1byte (8bits). any bytes of data may be serially transmitted. the receiving side will send an acknowledge signal to the transmission side each time 8bit data is transmitted. the acknowledge signal is sent immediately after falling to ?l? of scl 8bit clock pulses of data is transmitted, by releasing the sda by the transmission side that has asserted t he bus at that time and by turning sda to ?l? by receiving side. when transmission of 1by te data next to preceding 1byte of data is received the receiving side releases the sda pin at falling edge of t he scl 9bit of clock pulses or when the receiving side switches to the transmission side it starts data transmissi on. when the master is re ceiving side, it generates no acknowledge signal after last 1byte of data from the slave to tell the transmitter that data transmission has completed. the slave side (transmission side) continues to release the sda pi n so that the master will be able to generate stop condition, after falling edge of the scl 9bit of clock pulses. scl from the master sda from the transmission side sda from the receiving side 12 89 acknowledge signal start condition
R2025S/d 23 (3) data transmission format in i 2 c-bus i 2 c-bus has no chip enable signal line. in place of it, eac h device has a 7bit slave address allocated. the first 1byte is allocated to this 7bit address and to the command (r/w) for which data transmission direction is designated by the data transmission thereafter. 7bit addr ess is sequentially transmitted from the msb and 2 and after bytes are read, when 8bit is ?h? and when write ?l?. the slave address of the R2025S /d is specified at (0110010). at the end of data transmission / receiving, stop conditi on is generated to complete transmission. however, if start condition is generated without generating stop condi tion, repeated start condition is met and transmission / receiving data may be continue by setting the slave a ddress again. use this procedure when the transmission direction needs to be change during one transmission. s a a data /a p data is written to the slave from the master s 0 a slave address data a a p when data is read from the slave immediately after 7bit addressing from the master master to slave slave to master sr repeated start condition p stop condition a a /a a cknowledge signal r/w=1(read) (0110010) inform read has been completed by not generate an acknowledge signal to the slave side. data r/w=0(write) (0110010) when the transmission direction is to be changed during transmission. sr 1 0 a a r/w=0(write) a data r/w=1(read) (0110010) s 1 a /a p inform read has been completed by not generate an acknowledge signal to the slave side. data s start condition (0110010) slave address salve address slave address data data
R2025S/d 24 (4) data transmission write format in the R2025S/d although the i 2 c-bus standard defines a transmission format for the slave allocated for each ic, transmission method of address information in ic is not defined. the R2025S/d transmits data the internal address pointer (4bit) and the transmission format register (4bit) at the 1byte next to one which transmitted a slave address and a write command. for write operation only one transmissi on format is available and (0000) is set to the transmission format register. the 3byte transmits data to the address specified by the internal address pointer written to the 2byte. internal address pointer setting are automatically incremented for 4by te and after. note that when the internal address pointer is fh, it will change to 0h on transmitting the next byte. 1 a s 0 a data a data a p example of data writing (when writing to internal address eh to fh) master to slave slave to master s start condition p stop condition a a /a a cknowledge signal address pointer eh r/w=0(write) slave address (0110010) 1 1 0 0 0 0 0 0 0 0 0 1 1 1 transmission format register 0h writing of data to the internal address fh writing of data to the internal address eh (5) data transmission read format of the R2025S/d the R2025S/d allows the following three read out method of data an internal register. the first method to reading data from the internal register is to specify an internal address by setting the internal address pointer and the transmission format register described p24 (4), generate the repeated start condition (see p23 (3)) to change the data transmission direction to perfo rm reading. the internal address pointer is set to fh when the stop condition is met. therefore, this met hod of reading allows no insertion of stop condition before the repeated start condition. set 0h to the transmi ssion format register when this method used.
R2025S/d 25 s 0 a a data /a p example 1 of data read (when data is read from 2h to 4h) master to slave slave to master s start condition sr repeated start condition a a /a a cknowledge signal address pointer 2h repeated start condition 0 1 0 0 0 1 1 0 0 0 0 0 0 1 transmission format register 0h sr 1 0 a slave address (0110010) 1 0 0 0 0 1 a data a data reading of data from the internal address 3h r/w=1(read) r/w=0(write) p stop condition slave address (0110010) reading of data from the internal address 4h reading of data from the internal address 2h 1 the second method to reading data from the internal register is to start reading immediately after writing to the internal address pointer and the transmission format register. although this method is not based on i 2 c-bus standard in a strict sense it still effect ive to shorten read time to ease load to the master. set 4h to the transmission format register when this method used. 1 s a a data /a p example 2 of data read (when data is read from internal addresses eh to 1h) master to slave slave to master s start condition a a /a a cknowledge signal address pointer eh 0 1 1 0 0 0 1 transmission format register 4h 1 0 a slave address (0110010) 1 0 0 0 0 1 a data a data reading of data from the internal address eh r/w=0(write) p stop condition data reading of data from the internal address fh reading of data from the internal address 0h reading of data from the internal address 1h
R2025S/d 26 the third method to reading data from the internal register is to start reading immediately after writing to the slave address and r/w bit. since the internal address poin ter is set to fh by default as described in the first method, this method is only effective when reading is started from the internal address fh. s a a data /a p example 3 of data read (when data is read from internal addresses fh to 3h) master to slave slave to master s start condition a a /a a cknowledge signal 1 0 a slave address (0110010) 1 0 0 1 0 1 a data a data r/w=1(read) p stop condition data data reading of data from the internal address fh reading of data from the internal address 0h reading of data from the internal address 1h reading of data from the internal address 2h reading of data from the internal address 3h
R2025S/d 27 data transmission under special condition the R2025S/d holds the clock tentativel y for duration from start condition to avoid invalid read or write clock on carrying clock. when clock carried during this period, which will be adjusted within approx. 61 s from stop condition. to prevent invalid read or write, cl ock and calendar data shall be made during one transmission operation (from start condition to stop condition). when 0.5 to 1.0 second elapses after start condition, any access to the R2025S/d is automatically released to rel ease tentative hold of the cl ock, and access from the cpu is forced to be terminated (the same action as made stop condition is received: automatic resume function from i2c-bus interface). therefore, one access must be co mplete within 0.5 seconds. the automatic resume function prevents delay in clock ev en if scl is stopped from sudden failure of the system during clock read operation. also a second start condition after the first start condition and before the stop condition is regarded ?repeated start condition?. therefore, when 0.5 to 1.0 seconds passed after the first start condition, an access to the R2025S/d is automatically released. if access is tried after automatic resume function is activated, no acknowledge signal will be output for writing while ffh will be output for reading. the user shall always be able to access the real -time clock as long as three conditions are met. (1) no stop condition shall be generated until clock and ca lendar data read/write is started and completed. (2) one cycle read/write operation shall be complete within 0.5 seconds. (3) do not make start condition within 61 s from stop condition. when clock is carried during the access, which will be adjusted within approx. 61 s from stop condition. bad example of reading from seconds to hours (invalid read) (start condition) (read of seconds) (read of minutes) (stop condition) (start condition) (read of hour) (stop condition) assuming read was started at 05:59:59 p.m. and while reading seconds and minutes the time advanced to 06:00:00 p.m. at this time second digit is hold so r ead the read as 05:59:59. then t he R2025S/d confirms (stop condition) and carries second digit being hold and the time change to 06:00:00 p.m. then, when the hour digit is read, it changes to 6. the wrong results of 06:59:59 will be read.
R2025S/d 28 correction of time count deviations ? the necessity for correction of time count deviations the oscillation frequency for R2025S/d is corrected to 0 5ppm at 25 c in fabrication. oscillation frequency is the fastest at 25 c, (please see typical characteristics oscilla tion frequency deviation vs. operating temperature (p.41)). in normal condition, temper ature is not kept constant at 25 c. that is, R2025S/d loses without correction of time counts deviation. generally , a clock is corrected to gain 3 to 6ppm at 25 c. R2025S/d is corrected it by setting clock adjustment register. ricoh suggests to set 7fh to clock adjustment register (address 7h) for time setting to gain 3ppm at 25 c, for the equipment used indoors. and suggests to set 7eh to clock adjustment register (address 7h) for time setting to gain 6ppm at 25 c, for the equipment used outdoors. ? measurement of oscillation frequency frequency counter 32kout vss vdd clkc * 1) when power-on, the R2025S/d is configured to generate 32.768-khz clock pul ses for output from the 32kout pin. * 2) frequency counter with 6 (more preferably 7) or more digits on the order of 1ppm is recommended for use in the measurement of the oscillati on frequency of the oscillation circuit. ? oscillation adjustment circuit the oscillation adjustment circuit can be used to correct a time count gain or loss with high precision by varying the number of 1-second clock pulses once per 20 seconds. the oscillation adjustment circuit can be disabled by writing the settings of "*, 0, 0, 0, 0, 0, *" ("*" representing "0" or "1") to the f6, f5, f4, f3, f2, f1, and f0 bits in the oscillation adjustment circuit. conversely, when such oscillation adjustment is to be made, an appropriate oscillation adjustment value can be calculated by the equation bel ow for writing to the oscillation adjustment circuit. (1) when oscillation frequency (* 1) is higher than ta rget frequency (* 2) (causing time count gain) oscillation adjustment value (*3) = (osc illation frequency - target frequency + 0.1) oscillation frequency 3.051 10 -6 (oscillation frequency ? target frequency) 10 + 1 * 1) oscillation frequency: frequency of clock pulse output from the 32kout pin at normal temperature in the manner described in " p28 ? measurement of oscillation frequency". * 2) target frequency: desired frequency to be set. generally, a 32.768- khz crystal oscillator has such temperature characteristics as to have the highest oscillation frequenc y at normal temperature. consequently, the crystal oscillator is recommended to have target frequenc y settings on the order of 32.768 to 32.76810 khz (+3.05ppm relative to 32.768 khz). note that t he target frequency differs depending on the environment or location where the equipment incorporating the rtc is expected to be operated. * 3) oscillation adjustment value:
R2025S/d 29 value that is to be finally written to the f0 to f6 bi ts in the oscillation adjustm ent register and is represented in 7-bit coded decimal notation. (2) when oscillation frequency is equal to target fr equency (causing time count neither gain nor loss) oscillation adjustment value = 0, +1, -64, or ?63 (3) when oscillation frequency is lower than ta rget frequency (causing time count loss) oscillation adjustment value = (o scillation frequency - target frequency) oscillation frequency 3.051 10 -6 (oscillation frequency ? target frequency) 10 oscillation adjustment value calculations are exemplified below (a) for an oscillation frequency = 32768.85hz and a target frequency = 32768.05hz oscillation adjustment value = (32768.85 - 32768.05 + 0.1) / (32768.85 3.051 10 -6 ) (32768.85 - 32768.05) 10 + 1 = 9.001 9 in this instance, write the settings ((0),f6,f5,f4,f3,f2 ,f1,f0)=(0,0,0,0,1,0,0,1) in the oscillation adjustment register. thus, an appropriate oscillation adjustment val ue in the presence of any time count gain represents a distance from 01h. (b) for an oscillation frequency = 32762.22hz and a target frequency = 32768.05hz oscillation adjustment value = (32762.22 - 32768.05) / (32762.22 3.051 10 -6 ) (32762.22 - 32768.05) 10 = -58.325 -58 to represent an oscillation adjustment value of - 58 in 7-bit coded decimal notation, subtract 58 (3ah) from 128 (80h) to obtain 46h. in this instance, write the settings of ((0),f6,f5,f4,f3,f2,f1,f0) = (0,1,0,0,0,1,1,0) in the oscillation adjustment register. thus, an appropriate osc illation adjustment value in the presence of any time count loss represents a distance from 80h. notes: 1) oscillation adjustment does not affect the fr equency of 32.768-khz clock pulses output from the 32kout pin. 2) oscillation adjustment value range: when the o scillation frequency is higher than the target frequency (causing a time count gain), an appropriate time c ount gain ranges from -3.05ppm to -189.2ppm with the settings of "0, 0, 0, 0, 0, 1, 0" to "0, 1, 1, 1, 1, 1, 1" written to the f6, f5, f4, f3, f2, f1, and f0 bits in the oscillation adjustment register, thus allowing correction of a time count gain of up to +189.2ppm. conversely, when the oscillation frequenc y is lower than the target frequency (causing a time count loss), an appropriate time count gai n ranges from +3.05ppm to +189.2ppm with the settings of "1, 1, 1, 1, 1, 1, 1" to "1, 0, 0, 0, 0, 1, 0" written to the f6, f5, f4, f3, f2, f1, and f0 bits in the oscillation adjustment register, thus allowing co rrection of a time count loss of up to -189.2ppm. 3) if following 3 conditions are completed, actual cl ock adjustment value could be different from target adjustment value that set by oscillator adjustment function. 1. using oscillator adjustment function 2. access to R2025S/d at random, or synchronized with external clock that has no relation to R2025S/d, or synchronized with periodic interrupt in pulse mode. 3. access to R2025S/d more than 2 times per each second on average. for more details, please contact to ricoh. ? how to evaluate the clock gain or loss the oscillator adjustment circuit is configured to change ti me counts of 1 second on the basis of the settings of the oscillation adjustment register once in 20 seconds. the oscillation adjustment circuit does not effect the frequency of 32768hz-clock pulse output from the 32out pin. therefore, after writing the oscillation adjustment register, we cannot measure the clock error with probi ng 32kout clock pulses. the way to measure the clock
R2025S/d 30 error as follows: (1) output a 1hz clock pulse of pulse mode with interrupt pin set (0,0,x,x,0,0,1,1) to cont rol register 1 at address eh. (2) after setting the oscillation adjustment register, 1hz clock period changes every 20seconds ( or every 60 seconds) like next page figure. 1hz clock pulse t0 t0 t0 t1 1 time 19 times measure the interval of t0 and t1 with frequency count er. a frequency counter with 7 or more digits is recommended for the measurement. (3) calculate the typical period from t0 and t1 t = (19 t0+1 t1)/20 calculate the time error from t.
R2025S/d 31 power-on reset, oscillation halt sensing, and supply voltage monitoring ? pon, /xst, and vdet the power-on reset circuit is configured to reset contro l register1, 2, and clock adj ustment register when vdd power up from 0v. the oscillation halt sensing circuit is configured to record a halt on oscillation by 32.768-khz clock pulses. the supply voltage monitoring circuit is configured to record a drop in supply voltage below a threshold voltage of 2.1 or 1.3v. each function has a monitor bit. i.e. the pon bit is for the power-on reset circuit, and /xst bit is for the oscillation halt sensing circuit, and vdet is for the s upply voltage monitoring circuit. pon and vdet bits are activated to ?h?. however, /xst bit is activated to ?l?. the pon and vdet accept only the writing of 0, but /xst accepts the writing of 0 and 1. the pon bit is set to 1, when vdd power-up from 0v, but vdet is set to 0, and /xst is indefinite. the functions of these three monitor bits are shown in the table below. pon /xst vdet function monitoring for the power-on reset function monitoring for the oscillation halt sensing function a drop in supply voltage below a threshold voltage of 2.1 or 1.3v address d4 in address fh d5 in address fh d6 in address fh activated high low high when vdd power up from 0v 1 indefinite 0 accept the writing 0 only both 0 and 1 0 only the relationship between the pon, /xst, and vdet is shown in the table below. pon /xst vdet conditions of supply voltage and oscillation condition of oscillator, and back-up status 0 0 0 halt on oscillation, but no drop in vdd supply voltage below threshold voltage halt on oscillation cause of condensation etc. 0 0 1 halt on oscillation and drop in vdd supply voltage below threshold voltage, but no drop to 0v halt on oscillation cause of drop in back-up battery voltage 0 1 0 no drop in vdd supply voltage below threshold voltage and no halt in oscillation normal condition 0 1 1 drop in vdd supply voltage below threshold voltage and no halt on oscillation no halt on oscillation, but drop in back-up battery voltage 1 * * drop in supply voltage to 0v power-up from 0v,
R2025S/d 32 32768hz oscillation power-on reset flag (pon) oscillation halt sensin g fla g ( /xst ) threshold voltage (2.1v or 1.3v) vdd vdd supply voltage monitor flag (vdet) internal initialization period (1 to 2 sec.) vdet 0 /xst 1 pon 0 vdet 0 /xst 1 pon 1 vdet 0 /xst 1 pon 0 internal initialization period (1 to 2 sec.) when the pon bit is set to 1 in the control regi ster 2, the dev, f6 to f0, wale, dale, /12 ? 24, /clen2, test, ct2, ct1, ct0, vdsl, vdet, /clen1, ctfg, wafg, and da fg bits are reset to 0 in the oscillation adjustment register, the control register 1, and the c ontrol register 2. the pon bit is also set to 1 at power-on from 0 volts. < considerations in using oscillation halt sensing circuit > be sure to prevent the oscillation halt sensing circ uit from malfunctioning by preventing the following: 1) instantaneous power-down on the vdd 2) applying to individual pins voltage exc eeding their respective maximum ratings in particular, note that the /xst bit may fail to be se t to 0 in the presence of any applied supply voltage as illustrated below in such events as backup battery installa tion. further, give special considerations to prevent excessive chattering in the oscillation halt sensing circuit. vdd
R2025S/d 33 ? voltage monitoring circuit the vdd supply voltage monitoring circuit is configured to conduct a sampling operation during an interval of 7.8ms per second to check for a drop in supply voltage below a threshold voltage of 2.1 or 1.3v for the vdsl bit setting of 0 (the default setting) or 1, respectively, in the control register 2, thus minimizing supply current requirements as illustrated in the timing chart below. this circuit suspends a sampling operation once the vdet bit is set to 1 in the control register 2. the vdd s upply voltage monitor is useful for back-up battery checking. vd et (d6 in address fh) pon vd d 2.1v or 1.3v 1s vd et 0 7.8ms sampling timing for vdd supply voltage internal nitiali- zation period (1 to 2sec.) pon 0 vd et 0
R2025S/d 34 alarm and periodic interrupt the R2025S/d incorporates the alarm interrupt circuit and the periodic interrupt circuit that are configured to generate alarm signals and periodic interrupt signals, respecti vely, for output from the /intra or /intrb pins as described below. (1) alarm interrupt circuit the alarm interrupt circuit is configured to generate alar m signals for output from the /intra or /intrb, which is driven low (enabled) upon the occurrence of a match bet ween current time read by the time counters (the day-of-week, hour, and minute counters) and alarm time pres et by the alarm registers (the alarm_w registers intended for the day-of-week, hour, and minute digit settings and the alarm_d registers intended for the hour and minute digit settings). the alarm_w is output from the /intrb, and the alarm_d is output from /intra. (2) periodic interrupt circuit the periodic interrupt circuit is configured to generate eit her clock pulses in the pulse mode or interrupt signals in the level mode for output from the /intra pin depending on the ct2, ct1, and ct0 bit settings in the control register 1. the above two types of interrupt signals are monitored by the flag bits (i.e. the wafg, dafg, and ctfg bits in the control register 2) and enabled or disabled by the enabl e bits (i.e. the wale, dale, ct2, ct1, and ct0 bits in the control register 1) as listed in the table below. flag bits enable bits output pin alarm_ w wafg (d1 at address fh) wale (d7 at address eh) /intrb alarm_d dafg (d0 at address fh) dale (d6 at address eh) /intra peridic interrupt ctfg (d2 at address fh) ct2=ct1=ct0=0 (these bit setting of ?0? disable the periodic interrupt) (d2 to d0 at address eh) /intra * at power-on, when the wale, dale, ct2, ct1, and ct0 bits are set to 0 in the control register 1, the /intra and /intrb pins are driven high (disabled). * when two types of interrupt signals are output simult aneously from the /intra pin, the output from the /intra pin becomes an or waveform of their negative logic. example: combined output to /intra pin under control of /alarm_d and periodic interrupt periodic interrupt /intra /alarm_d in this event, which type of interrupt signal is output from the /intra pin can be confirmed by reading the dafg, and ctfg bit settings in the control register 2. ? alarm interrupt the alarm interrupt circuit is controlled by the enable bits (i.e. the wale and dale bits in the control register 1) and the flag bits (i.e. the wafg and dafg bits in the control register 2). the enable bits can be used to enable
R2025S/d 35 this circuit when set to 1 and to disable it when set to 0. when intended for reading, the flag bits can be used to monitor alarm interrupt signals. when intended for writing, the flag bits will cause no event when set to 1 and will drive high (disable) the alarm interrupt circuit when set to 0. the enable bits will not be affected even when the flag bits ar e set to 0. in this event, therefore, the alarm interrupt circuit will continue to function until it is dr iven low (enabled) upon the next occurrence of a match between current time and preset alarm time. the alarm function can be set by prese tting desired alarm time in the alarm registers (the alarm_w registers for the day-of-week digit settings and both the alarm_w regi sters and the alarm_d registers for the hour and minute digit settings) with the wale and dale bits once set to 0 and then to 1 in the control register 1. note that the wale and dale bits should be once set to 0 in order to disable the alarm interrupt circuit upon the coincidental occurrence of a match between current time and preset alar m time in the process of setting the alarm function. current time = preset alarm time wale 1 (dale) interval (1min.) during which a match between current time and preset alarm time occurs current time = preset alarm time wafg 1 (dale) current time = preset alarm time wale ? periodic interrupt setting of the periodic selection bits (ct2 to ct0) enables periodic interrupt to the cpu. there are two waveform modes: pulse mode and level mode. in the pulse mode, the output has a waveform duty cycle of around 50%. in the level mode, the output is cyclically driven low and, when the ctfg bit is set to 0, the output is return to high (off). description ct2 ct1 ct0 wave form mode interrupt cycle and falling timing 0 0 0 - off(h) (default) 0 0 1 - fixed at ?l? 0 1 0 pulse mode *1) 2hz(duty50%) 0 1 1 pulse mode *1) 1hz(duty50%) 1 0 0 level mode *2) once per 1 second (synchronized with second counter increment) 1 0 1 level mode *2) once per 1 minute (at 00 seconds of every minute) 1 1 0 level mode *2) once per hour (at 00 minutes and 00 seconds of every hour) 1 1 1 level mode *2) once per month (at 00 hours, 00 minutes, and 00 seconds of first day of every month)
R2025S/d 36 *1) pulse mode: 2-hz and 1-hz clock pulses are out put in synchronization with the increment of the second counter as illustrated in the timing chart below. /intra pin rewriting of the second counter ctfg bit a pprox. 92 s (increment of second counter) in the pulse mode, the increment of the second counter is delayed by approximately 92 s from the falling edge of clock pulses. consequently, time readings immediately after the falling edge of clock pulses may appear to lag behind the time counts of the real-tim e clocks by approximately 1 second. rewriting the second counter will reset the other time counters of less than 1 second, driving the /intra pin low. *2) level mode: periodic interrupt signals are output wi th selectable interrupt cycle settings of 1 second, 1 minute, 1 hour, and 1 month. the increment of the se cond counter is synchronized with the falling edge of periodic interrupt signals. for example, periodic inte rrupt signals with an interrupt cycle setting of 1 second are output in synchronization with the increment of the second counter as illustrated in the timing chart below. ctfg bit /intra pin setting ctfg bit to 0 setting ctfg bit to 0 (increment of second counter) (increment of second counter) (increment of second counter) *1), *2) when the oscillation adjustment circuit is used, the interrupt cycle will fluctuate once per 20sec. as follows: pulse mode: the ?l? period of output pulses w ill increment or decrement by a maximum of 3.784ms. for example, 1-hz clock pulses will have a duty cycle of 50 0.3784%. level mode: a periodic interrupt cycle of 1 sec ond will increment or decrement by a maximum of 3.784 ms.
R2025S/d 37 32-khz clock output for the r20225s/d, 32.768-khz clock pulses are output from the 32kout pin when the clkc pin is set to ?h?, and /clen1 or /clen bit is set to low. if clkc is set to low or opened, or /clen1 and /clen2 are set to high, the 32kout pin is driven low. /clen1 bit (d3 at address fh) /clen2 bit (d4 at address eh) clkc pin 32kout output pin (cmos push-pull output) 1 1 * * * 0 l 0(default) * 1 * 0(default) 1 32khz clock output for the R2025S/d, the 32kout pin output is synchronized wi th clkc pin input as illustrated in the timing chart below. 32kout pin clkc pin (/clen1 or /clen2= 0) max.76.3 s
R2025S/d 38 typical applications ? typical power circuit configurations sample circuit configuration 1 vdd vss system power supply *1) sample circuit configuration 2 *1) vss system power supply vdd primary battery *1) vss system power supply vdd secondary battery *1) install bypass capacitors for high-frequency and low-frequency applications in parallel in close vicinity to the R2025S/d. *1) when using an or diode as a power suppl y for the R2025S/d ensure that voltage exceeding the absolute maximum rating o f vdd+0.3v is not applied the 32kout pin.
R2025S/d 39 ? connection of /intra and /intrb pin the /intra and /intrb pins follow the n-channel open drain output logic and contains no protective diode on the power supply side. as such, it can be connected to a pu ll-up resistor of up to 5.5 volts regardless of supply voltage. vdd /intra or /intrb *1) b a backup power supply system power supply vss connection of 32kout pin as the 32kout pin is cmos output, the power supply voltage of the R2025S/d and any devices to be connected to the 32kout should be same. when the devices is pow ered down, the 32kout output should be disabled. when the clkc pin is connected to the system power s upply through the pull-up resistor, the pull-up resistor should be 0 ? to 10k ? , and the 32kout pin should be connect to t he host through the resistor (approx. 10k ? ). vdd clkc vss system power supply 32kout rn5vl xxc back-up power supply vdd host vss back-up power supply system power supply approx. 10k ? 32kout 0 to10k ? clkc *1) depending on whether the /intr a and /intrb pins are to be used during battery backup, it should be connected to a pull-up resistor at the following different positions: (1) position a in the left diagram when it is not to be used during battery backup. (2) position b in the left diagram when it is to be used during battery backup.
R2025S/d 40 typical characteristics test circuit frequency counter vdd 32kout vss cl timekeeping current vs. supply voltage timekeeping current vs. supply voltage (with no 32-khz clock output) (with 32-khz clock output) (output=open,topt=25 c) (output=open,topt=25 c) 0 0.2 0.4 0.6 0.8 1 0123456 supply voltage vdd(v) timekeeping current idd(ua) 0 1 2 3 4 5 6 7 8 9 10 0123456 supply voltage vdd(v) timekeeping current idd(ua) cpu access current vs. scl clock frequency ti mekeeping current vs. operating temperature (output=open, topt=25 c) (with no 32-khz output) (wiithout pull-up resister current) (output=open, vdd=3v) 0 10 20 30 40 50 0 100 200 300 400 scl clock frequency (khz) cpu access current idd(ua) 0 0.2 0.4 0.6 0.8 1 -60 -40 -20 0 20 40 60 80 10 0 operating temperature topt(celsius) timekeeping current idd(ua) vdd=5v vdd=3v topt : 25 c output : open scl, sda pin : vdd or vss cl=0pf cl=30pf
R2025S/d 41 oscillation frequency deviation vs. supply vo ltage oscillation frequency deviation vs. (topt=25 c) operating temperature (vdd=3v) -5 -4 -3 -2 -1 0 1 2 3 4 5 0123456 power supply vdd (v) oscillation frequency deviation (ppm) -120 -100 -80 -60 -40 -20 0 20 -60 -40 -20 0 20 40 60 80 100 operating temperature topt(celsius) oscillation frequency deviation (ppm) vol vs. iol(/intra, /intrb pin) cl kc pin input current vs. power supply (topt=25 c) (vin=vdd,topt=25 c) 0 5 10 15 20 25 30 35 00.20.40.60.81 vol (v) iol (ma) 0 0.2 0.4 0.6 0.8 1 0123456 power supply vdd (v) iclkc (ua) oscillation start time vs. power supply (topt=25 c) 0 100 200 300 400 500 0123456 power supply vdd (v) oscillation start time (ms) vdd=5v vdd=3v
R2025S/d 42 typical software-based operations ? initialization at power-on start *1) yes no vd et=0 ? warning back-up battery run-down set control register 1 and 2, etc. power-on *2) *4) *3) pon=1? yes no *1) after power-on from 0 volt, the start of oscillation and the process of internal initialization require a time span on the order of 1 to 2sec, so that access should be done after the lapse of this time span or more. *2) the pon bit setting of 0 in the control register 1 indicates power-on from backup battery and not from 0v. for further details, see "p.31 power-on reset, osc illation halt sensing, and supply voltage monitoring ? pon, /xst, and vdet ". *3) this step is not required when the supply voltage monitoring circuit is not used. *4) this step involves ordinary initialization including the oscillation adjustment register and interrupt cycle settings, etc. ? writing of time and calendar data write to tim e counter and calendar counter *2) stop condition *4) start condition *1) write to clock adjus tm ent register *3) *1) when writing to clock and calendar counters, do not insert stop condition until all times from second to year have been written to prevent error in writing time. (detailed in "p.27 data transmission under special condition". *2) any writing to the second counter will reset divider units lower than the second digits. *3) please see ?p,28 the necessity for correction of time count deviations ? *4) take care so that process from start condition to stop condition will be complete within 0.5sec. (detailed in "p.27 data transmission unde r special condition". the R2025S/d may also be initialized not at power-on but in the process of writing time and calendar data.
R2025S/d 43 ? reading time and calendar data (1) ordinary process of reading time and calendar data read from time counter and calendar counter *2) stop condition start condition *1) (2) basic process of reading time and calendar data with periodic interrupt function *2) other interrupt processes set periodic interrupt cycle selection bits ctfg=1? read from time counter and calendar counter yes no control register 2 (x1x1x011) generate interrupt in cpu *1) *3) *1) when reading to clock and calendar counters, do not insert stop condition until all times from second to year have been written to prevent error in writing time. (detailed in "p.27 data transmission under special condition". *2) take care so that process from start condition to stop condition will be complete within 0.5sec. (detailed in "p.27 data transmission unde r special condition". *1) this step is intended to select the level mode as a waveform mode for the periodic interrupt function. *2) this step must be completed within 0.5 second. *3) this step is intended to set the ctfg bit to 0 in the control register 2 to cancel an interrupt to the cpu.
R2025S/d 44 (3) applied process of reading time and calendar data with periodic interrupt function time data need not be read from all the time counters when used for such ordinary purposes as time count indication. this applied process can be used to read ti me and calendar data with substantial reductions in the load involved in such reading. for time indication in "day-of-month, day- of-week, hour, minute, and second" format: *2) other interrupts processes control register 1 (xxxx0 1 0 0 ) control register 2 (x1x1x011) sec.=00? yes no use previous min.,hr., day,and day-of-week data generate interrupt to cpu *1) *3) ctfg=1? control register 2 (x1x1x011) yes read min.,hr.,day, and day-of-week *4) no *1) this step is intended to select the level mode as a waveform mode for the periodic interrupt function. *2) this step must be completed within 0.5 sec. *3) this step is intended to read time data from all the time counters only in the first session of reading time data afte r writing time data. *4) this step is intended to set the ctfg bit to 0 in the control register 2 to cancel an interrupt to the cpu.
R2025S/d 45 ? interrupt process (1) periodic interrupt *2) other interrupt processes set periodic interrupt cycle selection bits ctfg=1? conduct periodic interrupt yes no control register 2 (x1x1x011) generate interrupt to cpu *1) (2) alarm interrupt *3) other interrupt processes set alarm min., hr., and day-of-week registers wa fg or da fg=1? conduct alarm interrupt yes no control register 2 (x1x1x101) generate interrupt to cpu *1) wale or dale 1 wale or dale 0 *2) *1) this step is intended to once disable the alarm interrupt circuit by setting the wale or dale bits to 0 in anticipation of the coincidental occurrence of a match between current time and preset alarm time in the process of setting the alarm interrupt function. *2) this step is intended to enable the alarm interrupt function after completion of all alarm interrupt settings. *3) this step is intended to once cancel the alarm interrupt function by writing the settings of "x,1,x, 1,x,1,0,1" and "x,1,x,1,x,1,1,0" to the alarm_w registers and the alarm_d registers, respectively. *1) this step is intended to select the level mode as a waveform mode for the periodic interrupt function. *2) this step is intended to set the ctfg bit to 0 in the control register 2 to cancel an interrupt to the cpu.
R2025S/d 46 land pattern (reference) ? R2025S (sop14) 8 0.7 1.27 1 7 8.32 p 1.27x6=7.62 14 5.4 1.4 1.4 unit:mm package top view 14 1 7 8 1. pad layout and size can modify by customers material, equipment, and method. please adjust pad layout according to your conditions. 2. in the mount area which descried as , is close to the inside oscillator circuit. to avoid the malfunction b y noise, check the other signal lines close to the area, do not intervene with the oscillator circuit. 3. a part of a metal case of the crystal may be seen in the area which described as in both sides of the package. it has no influence on the characteristics and quality of the product.
R2025S/d 47 ? r2025d (son22) 0.7 14 0.25 0.5 1 11 0.7 5.25 p 0.5x10=5.0 0.8 0.8 1.4 0.25 0.75 22 4.0 0.7 0.7 unit : mm package top view package bottom view 22 11 1 14 22 14 1 11 1. pad layout and size can modify by customers material, equipment, and method. please adjust pad layout according to your conditions. 2. any signal line should not pass through the area that descri bed as in the land pattern. if a signal line is located in that area, it may cause a short circuit with a tab suspension leads which is marked with in the figure above or unnecessary remainder of cut lead. 3. in the mount area which descried as , is close to the inside oscillator circuit. to avoid the malfunction b y noise, check the other signal lines close to the area, do not intervene with the oscillator circuit. 4. a part of a metal case of the crystal may be seen in the area that described as in both sides of the package. it has no influence on the characteristics and quality of the product.


▲Up To Search▲   

 
Price & Availability of R2025S

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X